package com.nchu.student_score.controller;

import com.nchu.student_score.dataObject.GradeResult;
import com.nchu.student_score.dataObject.StatisticsResult;
import com.nchu.student_score.service.StatisticsService;
import com.nchu.student_score.vo.ResultVo;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/statistics")
public class StatisticsController {
    @Resource
    StatisticsService statisticsService;

    @RequestMapping("getStuStatistics")
    public ResultVo<StatisticsResult> getStuStatistics(@RequestBody GradeResult input){
        return statisticsService.getStuStatistics(input);
    }
}
